package cn.bgs.pojo;
import java.time.LocalDateTime;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * 访客记录表
 * </p>
 *
 * @author cf
 * @since 2022-06-07
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="VisitorsRecord对象", description="访客记录表")
public class VisitorsRecord implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "访客记录自增")
    private Integer visitorsRecordId;

    @ApiModelProperty(value = "用户id")
    private Integer userId;

    @ApiModelProperty(value = "访问车牌号")
    private String visitorsLicencePlate;

    @ApiModelProperty(value = "小区中间表id")
    private Integer middleId;

    @ApiModelProperty(value = "访客性别")
    private String visitorsAge;

    @ApiModelProperty(value = "访客姓名")
    private String visitorsName;

    @ApiModelProperty(value = "访客手机号")
    private String visitorsPhone;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")//DateTimeFormat 是入参格式化；
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")//JsonFormat是出参格式化。
    @ApiModelProperty(value = "访问时间")
    private LocalDateTime accessTime;

    @ApiModelProperty(value = "时长")
    private Double duration;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")//DateTimeFormat 是入参格式化；
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")//JsonFormat是出参格式化。
    @ApiModelProperty(value = "结束时间")
    private LocalDateTime endTime;

    @ApiModelProperty(value = "是否驱车（是、否）")
    private String drive;

    @ApiModelProperty(value = "访问状态（生效中、已失效）")
    private String state;

    @ApiModelProperty(value = "通行证img")
    private String passUrl;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")//DateTimeFormat 是入参格式化；
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")//JsonFormat是出参格式化。
    @ApiModelProperty(value = "创建时间")
    private LocalDateTime createTime;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")//DateTimeFormat 是入参格式化；
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")//JsonFormat是出参格式化。
    @ApiModelProperty(value = "修改时间")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "删除标志（y是删除 n是未删除）")
    private String deleteFlag;

    @ApiModelProperty(value = "关联小区中间表")
    private CellIntermediate cellIntermediate;

    @ApiModelProperty(value = "小区名称")
    private String houseingname;


}
